let _img = document.querySelector(".ewmbox>img");
let _header = document.querySelector("header");
let Save_picture = document.querySelector(".Save_picture");
let head = document.querySelector(".head");
// console.log(_div);
// console.log(sessionStorage.getItem("img"));
_img.src = `${sessionStorage.getItem("img")}`;
_name = `${sessionStorage.getItem("_name")}`;
_da_time = sessionStorage.getItem("day_time");
cc_time = sessionStorage.getItem("cc_time");
// console.log(head);
// console.log(sessionStorage.getItem("_name"));
_header.innerHTML = `<div class="name_div" style="text-align: center">${_name}:</div>`
// console.log(sessionStorage.getItem("_phone"));
// console.log(_img.src);
Save_picture.addEventListener("click", function () {

    download(_img.src, "预约二维码");
})

function download(url, name) {
    const aLink = document.createElement('a')
    aLink.download = name
    aLink.href = url
    aLink.dispatchEvent(new MouseEvent('click', {}))
}
head.innerHTML=` <p>欢迎您在${_da_time}  ${cc_time}参观2019广州国际<br>花卉艺术展暨中国插花花艺展。</p>`